Dashboard for the Inference and Analysis of Networks from Expression data


This report was automatically generated by DIANE to improve research reproducibility.

It contains the main settings and results for the network inference tab of the application.

Your settings

Biological question

Normalization method:

print(r$norm_method)
## [1] "deseq2"

Input genes for network inference (DEGs from Differential expression tab) :

paste(input$input_deg_genes_net, ",", length(r$DEGs[[input$input_deg_genes_net]]) ,"genes")
## [1] "WTC WTAP , 2696 genes"

Those DEGs were studied via clustering :

if(!is.null(r$current_comparison)){
  print(input$input_deg_genes_net == r$current_comparison)
  if (input$input_deg_genes_net == r$current_comparison)
    print(paste(paste(input$input_cluster_genes_net, collapse = ', '), " were the clusters chosen for     inference"))
} else print(FALSE)
## [1] TRUE
## [1] "2, 1, 4, 3  were the clusters chosen for     inference"

Conditions used for the inference :

input$input_conditions_net
## [1] "WTC"     "WTCOR"   "WTAP"    "dyscC"   "dyscCOR" "dyscAP"

Were genes aggregated to remove splicing awareness? (sum of all transcripts variants for a gene)

r$splicing_aware
## [1] FALSE

Regulators

How many regulators were found among the input genes :

if(r$splicing_aware) {
  targets <- DIANE::get_locus(r$DEGs[[input$input_deg_genes_net]])
}else {
  targets <- r$DEGs[[input$input_deg_genes_net]]
}
regressors = intersect(targets, r$regulators)
length(regressors)
## [1] 25

(When only some clusters are selected, the regulators are still all the regulators present in the input DEGs)

Grouping correlated regulators

The regulators that were correlated above this threshold (Spearman correlation) were grouped :

input$cor_thr/100.0
## [1] 0.9

The grouping was performed using the modules of this correlation network :

if(!is.null(r$cor_network)){
    nodes <- r$cor_network$nodes
  nodes$label <- r$gene_info[match(nodes$id, rownames(r$gene_info)), "label"]
  
  visNetwork(nodes, r$cor_network$edges)%>% 
    visNodes(font = list("size" = 35))
}

Inference

Number of genes and regulators after grouping and potential splice variants aggregation:

paste("total genes :", ncol(r$networks[[input$input_deg_genes_net]]$mat), "regulators :", nrow(r$networks[[input$input_deg_genes_net]]$mat))
## [1] "total genes : 2686 regulators : 15"

Number of trees used for the inference :

input$n_trees
## [1] 1000

Importance metric used for the inference :

if(input$importance_metric){
  importance = "MSEincrease_oob"
}else
  importance = "node_purity"
importance
## [1] "node_purity"

Fully connected weighted network thresholding

Selected network density and corresponding number of edges :

paste("density:",input$density, ",", input$n_edges, "edges")
## [1] "density: 0.05 , 2014 edges"

Was statistical testing performed:

input$test_edges
## [1] FALSE

Results

Network topology

Network view :

if(!input$test_edges){
  DIANE::draw_network(nodes = r$networks[[input$input_deg_genes_net]]$nodes,
               edges = r$networks[[input$input_deg_genes_net]]$edges)
}else{
  DIANE::draw_discarded_edges(r$edge_tests$links, 
                       list(nodes = r$networks[[input$input_deg_genes_net]]$nodes,
                            edges = r$networks[[input$input_deg_genes_net]]$edges))
}

Number of nodes and number of edges of the network :

graph <- r$networks[[input$input_deg_genes_net]]$graph
paste(length(V(graph)), "nodes,", length(E(graph)), "edges")
## [1] "1250 nodes, 2014 edges"

Network degrees and betweenness distributions:

DIANE::draw_network_degrees(nodes = r$networks[[r$current_network]]$nodes,
                     graph = r$networks[[r$current_network]]$graph)
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.

To reproduce this result on identical data, specify this seed in DIANE’s interface (data import tab), or just before network inference and edge testing in command line.

r$seed
## [1] 34

Highly connected genes

Here are the genes of the network, ranked by degree. The full table, as well as the edges table, can be downloaded directly from the app as a csv file.

data <- r$networks[[r$current_network]]$nodes
    
columns <- c("label", "gene_type", "degree", "community")
if (!is.null(r$gene_info)) {
  columns <- unique(c(colnames(r$gene_info), columns))
}
data <- data[order(-data$degree),]
DT::datatable(data[, columns])

Network modules

Number of identified modules :

length(unique(r$networks[[r$current_network]]$membership))
## [1] 6

Modules view :

nodes <- r$networks[[r$current_network]]$nodes
    
nodes$group <- nodes$community
DIANE::draw_network(nodes = nodes,
             edges = r$networks[[r$current_network]]$edges)

Profiles of the modules :

if(r$splicing_aware) {
  data <- r$aggregated_normalized_counts
}else{
  data <- r$normalized_counts
}

if(sum(grepl("mean_", 
  r$networks[[r$current_network]]$nodes$id)) > 0){
  data <- r$grouped_normalized_counts
}

DIANE::draw_profiles(data = data,
              membership = r$networks[[r$current_network]]$membership,
              conds = r$networks[[r$current_network]]$conditions)